var e = require;
var t = module;
var o = exports;
var Adv_skd=require("./Adv_skd");
Object.defineProperty(o, "__esModule", {value: !0});
var n = e("sdkConfig"),
    a = (function () {
        function e() {
            (this.SW_SystemBanner = !1),
                (this.SW_SystemInters = !1),
                (this.SW_Video = !1),
                (this.SW_Native = !1),
                (this.SW_NativeBanner = !1),
                (this.SW_NativeInters = !1),
                (this.SW_Box = !1),
                (this.SW_Block = !1),
                (this.SW_BigNative = !1),
                (this.SW_IconNative = !1),
                (this.ID_SystemBanner = ""),
                (this.ID_SystemInters = "999"),
                (this.ID_Native = ""),
                (this.ID_NativeCustom = ""),
                (this.ID_Video = "999"),
                (this.ID_Box = ""),
                (this.ID_Block = ""),
                (this.NUM_NativeIntersP = 0),
                (this.NUM_NativeIntersReport = 1),
                (this.NUM_BannerErrP = 0),
                (this.NUM_BannerErrMost = 0),
                (this.NUM_BannerErrMust = 0),
                (this.NUM_VideoErrP = 0),
                (this.NUM_VideoErrMost = 0),
                (this.NUM_VideoErrMust = 0),
                (this.NUM_BannerUpdateTime = 30),
                (this.SW_SystemBannerFirst = !0),
                (this.NUM_BannerMostShow = 99),
                (this.timeout_showSystemBanner = null),
                (this.SW_IntersBaseControl = !1),
                (this.NUM_IntersStart = 0),
                (this.NUM_IntersIntervalNum = 0),
                (this.NUM_IntersIntervalTime = 0),
                (this.NUM_IntersDelayTime = 0),
                (this.NUM_IntersDelayP = 0),
                (this.NUM_NativeUpdateTime = 30),
                (this.SW_AddDesktop = !1),
                (this.SW_IntersIntervalToAddDesktop = !1),
                (this.NUM_AutoAddDeskMostTimes = 0),
                (this.NUM_IntersToAddDesktopNumber = 0),
                (this.SW_Statistics = !0),
                (this.SW_NavigateIcon = !1),
                (this.SW_NavigateGroup = !1),
                (this.SW_NavigateSettle = !1),
                (this.pushGameList = []),
                (this.bannerAd = null),
                (this.loadSucc_SystemBanner = !1),
                (this.loadSucc_Banner = !1),
                (this.hasShowBanner = !1),
                (this.interval_updateBanner = null),
                (this.timeout_checkBannerLoadSucc = null),
                (this.NUM_CheckBannerLoadSucc = 0),
                (this.NUM_MaxCheckBannerLoadSucc = 5),
                (this.systemIntersAd = null),
                (this.loadSucc_SystemInters = !1),
                (this.NUM_hasShowInters = 0),
                (this.NUM_intersNowInterval = 0),
                (this.NUM_IntersNowIntervalTime = 99),
                (this.NUM_IntersNowToAddDesktop = 0),
                (this.videoAd = null),
                (this.loadSucc_Video = !1),
                (this.callback_Video = null),
                (this.isShow_Video = !1),
                (this.videoPath = null),
                (this.gameRecorder = null),
                (this.callback_ShareVideo = null),
                (this.isAutoStop = null),
                (this.moreGamesBanner = null),
                (this.miniGame_version = "101"),
                (this.app_test_version = !1);
        }
        return (
            (e.prototype.GameVersion = function (e) {
                this.app_test_version = this.miniGame_version == e;
            }),
            (e.prototype.getGameTestVersion = function () {
                return this.app_test_version;
            }),
            (e.prototype.createAd = function () {
                this.SW_SystemBanner && "" != this.ID_SystemBanner && this.createSystemBanner(),
                    this.SW_SystemInters && "" != this.ID_SystemInters && this.createSystemInters(),
                    this.NUM_IntersIntervalTime > 0 && this.runIntersInterval(),
                    this.SW_Video && "" != this.ID_Video && this.createVideo(),
                    tt.setKeepScreenOn({
                        keepScreenOn: !0,
                        success: function () {
                            console.log("屏幕常亮已开启");
                        },
                        fail: function () {
                            console.log("setKeepScreenOn调用失败");
                        }
                    });
            }),
            (e.prototype.startLoadPushGamaes = function () {}),
            (e.prototype.createSystemBanner = function () {
                var e = this;
                if (
                    (console.log("ChaoQiGameSDK", "--createSystemBanner--"),
                    n.default.stringHasSpace(this.ID_SystemBanner))
                )
                    console.log(
                        "ChaoQiGameSDK",
                        "channelId:",
                        n.default.channelId,
                        "当前渠道系统banner广告ID中含有空字符串,请检查后台系统banner广告ID*********************"
                    );
                else {
                    var t = tt.getSystemInfoSync().windowWidth,
                        o = tt.getSystemInfoSync().windowHeight;
                    (this.bannerAd = tt.createBannerAd({
                        adUnitId: this.ID_SystemBanner,
                        adIntervals: 30,
                        style: {left: -1e3, top: -1e3}
                    })),
                        this.bannerAd.onResize(function (n) {
                            console.log("ChaoQiGameSDK", "Tiktok 系统banner广告重设位置", n, JSON.stringify(n)),
                                (e.bannerAd.style.top = o - n.height),
                                (e.bannerAd.style.left = (t - n.width) / 2);
                        }),
                        this.bannerAd.onLoad(function () {
                            console.log("ChaoQiGameSDK", "Tiktok 系统banner广告加载成功"),
                                (e.loadSucc_SystemBanner = !0),
                                e.hasShowBanner && e.showSystemBanner();
                        });
                }
            }),
            (e.prototype.createSystemInters = function () {
                var e = this;
                if (
                    (console.log("ChaoQiGameSDK", "--createSystemInters--"),
                    n.default.stringHasSpace(this.ID_SystemInters))
                )
                    console.log(
                        "ChaoQiGameSDK",
                        "channelId:",
                        n.default.channelId,
                        "当前渠道系统插屏广告ID中含有空字符串,请检查后台系统插屏广告ID*********************"
                    );
                else {
                    var t = tt.getSystemInfoSync().appName;
                    "Toutiao" == t || "Douyin" == t
                        ? ((this.systemIntersAd = tt.createInterstitialAd({adUnitId: Adv_skd.default.instance.getAds().interstitialId})),
                          this.systemIntersAd.onLoad(function () {
                              console.log("ChaoQiGameSDK", "Tiktok 插屏广告加载完成"), (e.loadSucc_SystemInters = !0);
                          }),
                          this.systemIntersAd.onError(function (t) {
                              console.log("ChaoQiGameSDK", "Tiktok 插屏加载失败：" + JSON.stringify(t)),
                                  e.systemIntersAd &&
                                      setTimeout(function () {
                                          e.systemIntersAd && e.systemIntersAd.load();
                                      }, 3e4);
                          }),
                          this.systemIntersAd.onClose(function () {
                              console.log("ChaoQiGameSDK", "Tiktok 关闭插屏,重新创建插屏广告"),
                                  (e.NUM_IntersNowIntervalTime = 0),
                                  e.systemIntersAd.destroy(),
                                  e.createSystemInters(),
                                  (e.loadSucc_SystemInters = !1),
                                  e.systemIntersAd.load();
                          }),
                          this.systemIntersAd.load())
                        : console.log("ChaoQiGameSDK", "非抖音/今日头条平台 或抖音平台版本过低 return");
                }
            }),
            (e.prototype.createVideo = function () {
                var e = this;
                console.log("ChaoQiGameSDK", "--createVideo--"),
                    n.default.stringHasSpace(this.ID_Video)
                        ? console.log(
                              "ChaoQiGameSDK",
                              "channelId:",
                              n.default.channelId,
                              "当前渠道视频广告ID中含有空字符串,请检查后台视频广告ID*********************"
                          )
                        : ((this.videoAd = tt.createRewardedVideoAd({adUnitId: Adv_skd.default.instance.getAds().videoAdId})),
                          this.videoAd.onLoad(function () {
                              console.log("ChaoQiGameSDK", "Tiktok 视频广告加载完成"), (e.loadSucc_Video = !0);
                          }),
                          this.videoAd.onError(function (t) {
                              console.log("ChaoQiGameSDK", "Tiktok 视频广告加载失败 ：" + JSON.stringify(t)),
                                  (e.loadSucc_Video = !1),
                                  setTimeout(function () {
                                      e.videoAd && e.videoAd.load();
                                  }, 3e4);
                          }),
                          this.videoAd.onClose(function (t) {
                              setTimeout(function () {
                                  t.isEnded
                                      ? (console.log("ChaoQiGameSDK", "Tiktok 激励视频广告完成，发放奖励"),
                                        e.callback_Video &&
                                            (e.callback_Video(!0), (e.loadSucc_Video = !1), e.videoAd.load()))
                                      : (console.log("ChaoQiGameSDK", "Tiktok 激励视频广告取消，不发放奖励"),
                                        e.callback_Video &&
                                            (e.callback_Video(!1), (e.loadSucc_Video = !1), e.videoAd.load())),
                                      (e.isShow_Video = !1);
                              }, 500);
                          }),
                          this.videoAd.load());
            }),
            (e.prototype.showBanner = function () {
                this.loadSucc_Banner
                    ? this.hasShowBanner
                        ? console.log("ChaoQiGameSDK", "已经调用过showBanner,请勿重复调用")
                        : ((this.hasShowBanner = !0),
                          this.SW_SystemBanner && (this.showSystemBanner(), this.updateSystemBanner()))
                    : this.checkBannerLoadSucc();
            }),
            (e.prototype.hideBanner = function () {
                (this.hasShowBanner = !1),
                    this.hideSystemBanner(),
                    this.interval_updateBanner && clearInterval(this.interval_updateBanner),
                    this.timeout_checkBannerLoadSucc && clearTimeout(this.timeout_checkBannerLoadSucc);
            }),
            (e.prototype.getIntersFlag = function () {
                return this.loadSucc_SystemInters || (this.SW_AddDesktop && this.NUM_AutoAddDeskMostTimes > 0);
            }),
            (e.prototype.showInters = function () {
                var e = this;
                if (
                    (this.NUM_hasShowInters++,
                    this.SW_IntersIntervalToAddDesktop &&
                        this.NUM_hasShowInters <= this.NUM_IntersToAddDesktopNumber &&
                        (console.log(
                            "ChaoQiGameSDK",
                            "第" + this.NUM_IntersToAddDesktopNumber + "次插屏变添加桌面",
                            "当前第" + this.NUM_hasShowInters + "次"
                        ),
                        this.NUM_hasShowInters == this.NUM_IntersToAddDesktopNumber))
                )
                    this.getAddDesktopFlag(function (t) {
                        t && (console.log("ChaoQiGameSDK", "插屏变添加桌面"), e.addDesktop(function () {}));
                    });
                else {
                    if (this.SW_IntersBaseControl) {
                        if (this.NUM_hasShowInters < this.NUM_IntersStart)
                            return void console.log(
                                "ChaoQiGameSDK",
                                "插屏开始次数未达到",
                                this.NUM_hasShowInters,
                                "目标次数",
                                this.NUM_IntersStart
                            );
                        if (this.NUM_intersNowInterval < this.NUM_IntersIntervalNum)
                            return (
                                console.log(
                                    "ChaoQiGameSDK",
                                    "插屏间隔次数未达到",
                                    this.NUM_intersNowInterval,
                                    "目标次数",
                                    this.NUM_IntersIntervalNum
                                ),
                                void this.NUM_intersNowInterval++
                            );
                        if (this.NUM_IntersNowIntervalTime < this.NUM_IntersIntervalTime)
                            return (
                                console.log(
                                    "ChaoQiGameSDK",
                                    "插屏间隔时间未达到",
                                    this.NUM_IntersNowIntervalTime,
                                    "目标时间",
                                    this.NUM_IntersIntervalTime
                                ),
                                void (
                                    this.SW_AddDesktop &&
                                    this.NUM_IntersNowToAddDesktop < this.NUM_AutoAddDeskMostTimes &&
                                    this.getAddDesktopFlag(function (t) {
                                        t &&
                                            (e.NUM_IntersNowToAddDesktop++,
                                            e.addDesktop(function () {
                                                console.log("ChaoQiGameSDK", "插屏间隔弹桌面");
                                            }));
                                    })
                                )
                            );
                    }
                    (this.NUM_intersNowInterval = 0),
                        this.NUM_IntersDelayTime > 0 && Math.floor(100 * Math.random()) < this.NUM_IntersDelayP
                            ? (console.log("ChaoQiGameSDK", "插屏延迟时间(ms):" + this.NUM_IntersDelayTime),
                              setTimeout(function () {
                                  e.loadSucc_SystemInters && e.showSystemInters();
                              }, this.NUM_IntersDelayTime))
                            : this.loadSucc_SystemInters && this.showSystemInters();
                }
            }),
            (e.prototype.getVideoFlag = function () {
                return this.loadSucc_Video;
            }),
            (e.prototype.showVideo = function (e) {
                var t = this;
                this.isShow_Video
                    ? console.log("ChaoQiGameSDK", "视频正在播放中,请勿多次点击！")
                    : ((this.isShow_Video = !0),
                      (this.callback_Video = e),
                      this.videoAd
                          ? this.videoAd
                                .show()
                                .then(function () {
                                    console.log("ChaoQiGameSDK", "Tiktok 激励视频广告显示成功");
                                })
                                .catch(function (e) {
                                    console.log("ChaoQiGameSDK", "Tiktok 激励视频广告组件出现问题", JSON.stringify(e)),
                                        t.videoAd.load().then(function () {
                                            console.log("ChaoQiGameSDK", "Tiktok 激励视频广告手动加载成功"),
                                                t.videoAd.show().catch(function (e) {
                                                    console.log(
                                                        "ChaoQiGameSDK",
                                                        "Tiktok 激励视频广告播放失败",
                                                        JSON.stringify(e)
                                                    ),
                                                        (t.isShow_Video = !1),
                                                        t.callback_Video(!1);
                                                });
                                        });
                                })
                          : ((this.isShow_Video = !1), this.callback_Video(!1)));
            }),
            (e.prototype.getNativeIconFlag = function () {
                return !1;
            }),
            (e.prototype.showNativeIcon = function () {}),
            (e.prototype.hideNativeIcon = function () {}),
            (e.prototype.getNativeImageFlag = function () {
                return !1;
            }),
            (e.prototype.showNativeImage = function () {}),
            (e.prototype.hideNativeImage = function () {}),
            (e.prototype.getNativeAdFlag = function () {
                return !1;
            }),
            (e.prototype.getNativeAdInfo = function () {
                return null;
            }),
            (e.prototype.reportNativeAdShow = function () {}),
            (e.prototype.reportNativeAdClick = function () {}),
            (e.prototype.getNavigateIconFlag = function () {
                return !1;
            }),
            (e.prototype.showNavigateIcon = function () {}),
            (e.prototype.hideNavigateIcon = function () {}),
            (e.prototype.getNavigateGroupFlag = function () {
                return !1;
            }),
            (e.prototype.showNavigateGroup = function () {}),
            (e.prototype.hideNavigateGroup = function () {}),
            (e.prototype.getNavigateSettleFlag = function () {
                return !1;
            }),
            (e.prototype.showNavigateSettle = function () {}),
            (e.prototype.hideNavigateSettle = function () {}),
            (e.prototype.getNavigateBoxBannerFlag = function () {
                return !1;
            }),
            (e.prototype.showNavigateBoxBanner = function () {}),
            (e.prototype.hideNavigateBoxBanner = function () {}),
            (e.prototype.getNavigateBoxPortalFlag = function () {
                return !1;
            }),
            (e.prototype.showNavigateBoxPortal = function () {}),
            (e.prototype.setGroup = function () {}),
            (e.prototype.hasAddDesktopFunc = function () {
                return !0;
            }),
            (e.prototype.getAddDesktopFlag = function (e) {
                tt.checkShortcut({
                    success: function (t) {
                        !t.status.exist || t.status.needUpdate
                            ? (console.log("ChaoQiGameSDK", "checkShortcut res:", JSON.stringify(t)),
                              console.log("ChaoQiGameSDK", "Tiktok 未创建桌面图标或图标需要更新"),
                              e(!0))
                            : (console.log("ChaoQiGameSDK", "Tiktok 已创建桌面图标"), e(!1));
                    },
                    fail: function (t) {
                        console.log("ChaoQiGameSDK", "Tiktok 添加桌面图标失败：", JSON.stringify(t.errMsg)), e(!1);
                    }
                });
            }),
            (e.prototype.addDesktop = function (e) {
                tt.addShortcut({
                    success: function () {
                        console.log("ChaoQiGameSDK", "添加桌面成功"), e(!0);
                    },
                    fail: function (t) {
                        console.log("ChaoQiGameSDK", "添加桌面失败：", JSON.stringify(t)), e(!1);
                    }
                });
            }),
            (e.prototype.phoneVibrate = function (e) {
                "long" == e
                    ? tt.vibrateLong({
                          success: function () {},
                          fail: function (e) {
                              console.log("ChaoQiGameSDK", "Tiktok vibrateLong调用失败：", JSON.stringify(e));
                          }
                      })
                    : "short" == e &&
                      tt.vibrateShort({
                          success: function () {},
                          fail: function (e) {
                              console.log("ChaoQiGameSDK", "Tiktok vibrateShort调用失败：", JSON.stringify(e));
                          }
                      });
            }),
            (e.prototype.startGameVideo = function (e) {
                var t = this;
                (this.videoPath = null),
                    e || (e = 10),
                    (this.gameRecorder = tt.getGameRecorderManager()),
                    this.gameRecorder.onStart(function () {
                        console.log("ChaoQiGameSDK", "Tiktok 录屏开始");
                    }),
                    this.gameRecorder.onStop(function (e) {
                        console.log("ChaoQiGameSDK", "Tiktok 录屏结束", e.videoPath),
                            (t.videoPath = e.videoPath),
                            t.callback_ShareVideo
                                ? (t.callback_ShareVideo(t.videoPath), (t.callback_ShareVideo = null))
                                : (t.isAutoStop = !0);
                    }),
                    this.gameRecorder.onError(function (e) {
                        console.log("ChaoQiGameSDK", "Tiktok 录屏错误:" + JSON.stringify(e));
                    }),
                    this.gameRecorder.start({duration: e});
            }),
            (e.prototype.pauseGameVideo = function () {
                console.log("ChaoQiGameSDK", "Tiktok 暂停录屏=================="),
                    this.gameRecorder && this.gameRecorder.pause();
            }),
            (e.prototype.resumeGameVideo = function () {
                console.log("ChaoQiGameSDK", "Tiktok 继续录屏=================="),
                    this.gameRecorder && this.gameRecorder.resume();
            }),
            (e.prototype.stopGameVideo = function (e) {
                if (
                    ((this.callback_ShareVideo = e),
                    console.log("ChaoQiGameSDK", "Tiktok stopGameVideo======================="),
                    this.isAutoStop)
                )
                    return (
                        this.callback_ShareVideo(this.videoPath),
                        (this.callback_ShareVideo = null),
                        void (this.isAutoStop = !1)
                    );
                this.gameRecorder && this.gameRecorder.stop();
            }),
            (e.prototype.shareVideo = function (e, t, o, n, a) {
                console.log("ChaoQiGameSDK", "Tiktok 分享录屏", n),
                    n
                        ? tt.shareAppMessage({
                              channel: "video",
                              title: e,
                              desc: t,
                              extra: {videoPath: n, videoTopics: [o], hashtag_list: [o]},
                              success: function () {
                                  console.log("ChaoQiGameSDK", "Tiktok 分享视频成功"), a(!0);
                              },
                              fail: function (e) {
                                  console.log("ChaoQiGameSDK", "Tiktok 分享视频失败：", JSON.stringify(e)), a(!1);
                              }
                          })
                        : console.log("ChaoQiGameSDK", "视频地址为空 return");
            }),
            (e.prototype.jumpToMoreGamesCenter = function () {
                "android" == tt.getSystemInfoSync().platform
                    ? (console.log("ChaoQiGameSDK", "jumpToMoreGamesCenter====================="),
                      tt.showMoreGamesModal({
                          appLaunchOptions: [{appId: "ttXXXXXX", query: "foo=bar&baz=qux", extraData: {}}],
                          success: function (e) {
                              console.log("ChaoQiGameSDK", "success", e.errMsg);
                          },
                          fail: function (e) {
                              console.log("ChaoQiGameSDK", "fail", e.errMsg);
                          }
                      }))
                    : console.log("ChaoQiGameSDK", "非安卓手机,请隐藏更多游戏按钮 return");
            }),
            (e.prototype.showMoreGamesBanner = function () {
                "android" == tt.getSystemInfoSync().platform
                    ? (console.log("ChaoQiGameSDK", "Tiktok showMoreGamesBanner==============="),
                      (this.moreGamesBanner = tt.createMoreGamesBanner({
                          style: {
                              left: 0,
                              top: 0,
                              width: 150,
                              height: 40,
                              verticalAlign: "bottom",
                              horizontalAlign: "center"
                          },
                          appLaunchOptions: [{appId: "ttXXXXXX", query: "foo=bar&baz=qux", extraData: {}}]
                      })),
                      this.moreGamesBanner.onError(function (e) {
                          console.log("ChaoQiGameSDK", "Tiktok 更多游戏横幅出错:", JSON.stringify(e));
                      }),
                      this.moreGamesBanner.show())
                    : console.log("ChaoQiGameSDK", "非安卓手机,不能展示更多游戏横幅");
            }),
            (e.prototype.hideMoreGamesBanner = function () {
                console.log("ChaoQiGameSDK", "Tiktok hideMoreGamesBanner==============="),
                    this.moreGamesBanner && this.moreGamesBanner.hide();
            }),
            (e.prototype.showFavoriteGuide = function (e, t, o) {
                console.log("ChaoQiGameSDK", "Tiktok showFavoriteGuide===============", e, t, o),
                    tt.showFavoriteGuide({
                        type: e,
                        content: t,
                        position: o,
                        success: function () {
                            console.log("ChaoQiGameSDK", "引导组件展示成功");
                        },
                        fail: function (e) {
                            console.log("ChaoQiGameSDK", "引导组件展示失败:" + JSON.stringify(e));
                        }
                    });
            }),
            (e.prototype.getBoxFlag = function () {
                return !1;
            }),
            (e.prototype.showAppBox = function () {}),
            (e.prototype.getBlockFlag = function () {
                return !1;
            }),
            (e.prototype.showBlock = function () {}),
            (e.prototype.hideBlock = function () {}),
            (e.prototype.getVideoIntersFlag = function () {
                return !1;
            }),
            (e.prototype.showVideoInters = function () {}),
            (e.prototype.exitTheGame = function () {}),
            (e.prototype.reportAnalytics = function (e, t) {
                tt.reportAnalytics(e, t);
            }),
            (e.prototype.showAuthentication = function () {}),
            (e.prototype.visitorExperience = function () {}),
            (e.prototype.showNativeAd = function () {}),
            (e.prototype.getOPPOShowMoreGameFlag = function () {}),
            (e.prototype.showOPPOMoreGame = function () {}),
            (e.prototype.hasNetwork = function () {}),
            (e.prototype.showReviewAlert = function () {}),
            (e.prototype.showiOSADWithScene = function () {}),
            (e.prototype.showiOSADWithType = function () {}),
            (e.prototype.videoUIShow = function () {}),
            (e.prototype.showPrivacyAgreement = function () {}),
            (e.prototype.getErrBannerFlag = function () {
                return !1;
            }),
            (e.prototype.showErrBanner = function (e) {
                e(!1);
            }),
            (e.prototype.hideErrBanner = function () {}),
            (e.prototype.getErrVideoFlag = function () {
                return !1;
            }),
            (e.prototype.buyProps = function (e, t, o, n) {
                n(!1, "");
            }),
            (e.prototype.payComplete = function () {}),
            (e.prototype.checkBannerLoadSucc = function () {
                var e = this;
                if (
                    ((this.loadSucc_Banner = this.SW_SystemBanner && this.loadSucc_SystemBanner),
                    console.log(
                        "ChaoQiGameSDK",
                        "banner加载成功?",
                        this.loadSucc_Banner,
                        ++this.NUM_CheckBannerLoadSucc
                    ),
                    this.timeout_checkBannerLoadSucc && clearTimeout(this.timeout_checkBannerLoadSucc),
                    this.loadSucc_Banner)
                )
                    this.showBanner();
                else {
                    if (this.NUM_CheckBannerLoadSucc >= this.NUM_MaxCheckBannerLoadSucc) return;
                    this.timeout_checkBannerLoadSucc = setTimeout(function () {
                        e.checkBannerLoadSucc();
                    }, 5e3);
                }
            }),
            (e.prototype.showSystemBanner = function () {
                var e = this;
                this.bannerAd
                    ? (console.log("ChaoQiGameSDK", "Tiktok showSystemBanner========================"),
                      this.bannerAd.show())
                    : (this.createSystemBanner(),
                      (this.timeout_showSystemBanner = setTimeout(function () {
                          e.bannerAd && e.showSystemBanner();
                      }, 1e3)));
            }),
            (e.prototype.updateSystemBanner = function () {
                var e = this;
                this.interval_updateBanner && clearInterval(this.interval_updateBanner),
                    (this.interval_updateBanner = setInterval(function () {
                        console.log("ChaoQiGameSDK", "Tiktok updateSystemBanner========================"),
                            e.bannerAd.destroy(),
                            (e.bannerAd = null),
                            e.createSystemBanner();
                    }, 1e3 * this.NUM_BannerUpdateTime));
            }),
            (e.prototype.hideSystemBanner = function () {
                this.bannerAd &&
                    (console.log("ChaoQiGameSDK", "Tiktok hideSystemBanner========================"),
                    this.bannerAd.hide()),
                    this.timeout_showSystemBanner && clearTimeout(this.timeout_showSystemBanner),
                    this.interval_updateBanner && clearInterval(this.interval_updateBanner);
            }),
            (e.prototype.showSystemInters = function () {
                this.systemIntersAd &&
                    this.loadSucc_SystemInters &&
                    (console.log("ChaoQiGameSDK", "Tiktok showSystemInters========================"),
                    this.systemIntersAd.show());
            }),
            (e.prototype.runIntersInterval = function () {
                var e = this;
                this.NUM_IntersIntervalTime > 0 &&
                    setInterval(function () {
                        e.NUM_IntersNowIntervalTime++;
                    }, 1e3);
            }),
            e
        );
    })();
o.default = a;
